const QiniuManager = require('./src/utils/QiniuManager')
const path = require('path')

const accessKey = 'nzxCQpB1wc9C-T_XPAIHqs_gGi_itNepD6hHfmew'; // AK
const secretKey = 'eaK7aWcWCywrx6Qm25-HaOvTB_AMnW-q2JIntYqk'; // SK
const bucket = 'cloud-doc-youchen' // 空间名称
const localFile = "E:\\document\\electionDocument";
const publicBucketDomain = 'http://cloud-doc.youchen-blog.cn'
const key = 'IPC进行通讯.md';
const manager = new QiniuManager(accessKey, secretKey, bucket, publicBucketDomain)
manager.downloadFile(key, path.join(localFile, key)).then(data=>{
    console.log(data)
}).catch(err=>{
    console.log(err)
})